<script setup lang="ts">
import Icon from '../../../components/Icon.vue';
import { IconInput } from '../../../components/useIcon';
import { copy } from '../copy';


defineProps<{
    iconList?: string[]
    tag: keyof IconInput
}>()
</script>

<template>
    <div class="max-h-full flex flex-wrap overflow-x-hidden overflow-y-auto" v-if="iconList">
        <div
            class="p-2 h-fit hover:bg-gray-300 overflow-hidden"
            style="max-width: 48px;"
            v-for="item in iconList"
        >
            <Icon @click="copy(item)" :title="item" :type="tag" class="text-2xl">{{ item }}</Icon>
        </div>
    </div>
</template>
